﻿<div class="sample_title">Simple Datagrid</div>

sample:<br />
<div class="sample_preview">
    <script type="text/javascript"><!--//--><![CDATA[//><!--
        $(document).ready(function() {
            // Create Datagrid
            $('#datagrid1').grid(
            {
                title: 'User',
                url: gs_path + '/ITUser/GetData',
                colModel: [{ name: 'user_id', label: 'User ID' },
                           { name: 'user_name', label: 'User Name' },
                           { name: 'description', label: 'Deskripsi' },
                           { name: 'email', label: 'Email' }],
                sortname: 'user_id',
                sortorder: 'asc'
            });
        });
        //--><!]]></script>
    <div id="datagrid1"></div>
</div><br />
code:
<div class="sample_code" rel="brush: js; html-script: false;">
    &lt;script type="text/javascript"&gt
        $(document).ready(function() {
            // Create Datagrid
            $('#datagrid').grid(
            {
                title: 'User',
                url: gs_path + '/ITUser/GetData',
                colModel: [{ name: 'user_id', label: 'User ID' },
                           { name: 'user_name', label: 'User Name' },
                           { name: 'description', label: 'Deskripsi' },
                           { name: 'email', label: 'Email' }],
                sortname: 'user_id',
                sortorder: 'asc'
            });
        });
    &lt;/script&gt;
        
    &lt;div id="datagrid"&gt;&lt;/div&gt;
    
    <% for (int i = 0, max_i = 15; i < max_i; i++) { Response.Write("<br />"); } %>
</div>